package com.xxjqr.rbac.entity.dto;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;

@AllArgsConstructor
@Data
@NoArgsConstructor
public class JobDto {
    private Long id;
    @NotEmpty(message = "岗位名称不能为空")
    private String name;
    @NotEmpty(message = "岗位编码不能为空")
    private String code;
    @NotNull(message = "排序不能为空")
    private Integer sort;
    @NotNull(message = "状态不能为空")
    @Range(min = 0,max = 1,message = "状态只能为 0 1")
    private Integer status;
    private String remarks;
}
